<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8" />
        <meta http-equiv="X-UA-Compatible" content="IE=edge" />
        <meta name="viewport" content="width=device-width, initial-scale=1.0" />
        <title>Document</title>
    </head>
    <body>
        <script>
            const data = [
                { name: "小a", gender: "女", age: 21, grade: "大一" },
                { name: "小c", gender: "男", age: 21, grade: "大一" },
                { name: "小e", gender: "女", age: 21, grade: "大三" },
                { name: "小g", gender: "女", age: 21, grade: "大一" },
            ];
            let res = [];
            for (var i = 0; i < data.length; i++) {
                let one =data[i];
                if(one.gender==="女"&&one.grade==="大一"){
                    res.push(one.name)
                }
            }
            console.log(res);
        </script>
    </body>
</html>
